<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" style="overflow: hidden">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>${Title}</title>
<link rel="shortcut icon" href="${res}favicon.ico" type="image/x-icon" />
 <!--Basic Styles-->
<link href="../../../framework/css/font.css" rel="stylesheet" />
<link href="../../../framework/miniui/themes/material/miniui.css" rel="stylesheet" />
<link href="../../../framework/css/app.min.1.css" rel="stylesheet" type="text/css" />
<link href="../../../framework/css/app.min.2.css" rel="stylesheet" type="text/css" />
<script src="../../../framework/main.js" type="text/javascript"></script>
<style type="text/css">
    html, body{
        margin:0;padding:0;border:0;width:100%;height:100%;overflow:hidden;
    }    
    </style>
</head>
<body class="body-detail">
	<script>
		Page.onLoad(function(){
			mini.get('dg1').load();	
		});
		//删除项目 
		function removeRow() {
			var arr = mini.get("dg1").getSelectedValue();
			if (!arr || arr.length == 0) {
				top.mini.showTips({
					content : '请先选择要删除的记录！',
					state : 'info'
				});
				return;
			}
			
			top.mini.confirm("确定要删除么", function(action) {
				if (action == "ok") {
					var dc = {
						Id : arr.join()
					};
					Server.sendRequest("NewAccountNumber.deletePublicityId", dc, function(response) {
						if (response.Status == 1) {
							top.mini.showTips({
								content : response.Message,
								state : 'success'
							});
							mini.get('dg1').clearSelect();
							mini.get('dg1').reload();
						} else {
							top.mini.warn(response.Message);
						}
					});
				}
			});
		}
		function action(e) {
			var record = e.record
			e.cellStyle = "text-align:left";
			
	        return '<a href="javascript:viewUser(\'' + record.Id + '\','+record.Company+')">查看</a>';
		}
		//查看公示
		function viewUser(member, company) {
		 	mini.open({
				width: 900,
				height : 800,
				title : "查看公示信息",
				url : "${ctx}eao/setting/viewPublicity.jhtml?Id=" + member + "&Company=" + company,
				onLoad : function(){}
			});
		}
	</script>
	
	<div class="search-area">
		<div class="pull-left">
			<a class="mini-button" 
				iconCls="icon-remove" onclick="removeRow()" plain="true">删除</a> 
		</div>
	</div>
	
	<div class="mini-fit" style="padding:0 10px 10px 10px;">
		<div id="dg1" class="mini-datagrid z-depth-1" style="width:100%;height:100%;" method="NewAccountNumber.findPublicityWithTime" idField="Id" multiSelect="true">
		   <div property="columns">
				<div type="checkcolumn"></div>
				<div type="indexcolumn"></div>
				<div field="Title" width="12%">项目名称</div>
				<div field="RealName" width="13%">姓名</div>
				<div field="PublicityTime" dateFormat="yyyy-MM-dd hh:mm:ss" width="12%">时间</div>
				<div name="action" renderer="action"  width="16%">操作</div>
			</div>
		</div>
	</div>
</body>
</html>